package com.rockwell.maze800.test;

import org.opencv.core.Point;

import com.rockwell.maze800.model.IDetector;

public class DummyTreasureDetector implements IDetector {

	boolean[] m_treasurePresent;
	double[] m_treasurePositionData;
	
	int m_treasurePresentIndex;
	int m_treasurePositionIndex;
	
	public DummyTreasureDetector(double[] treasurePositionData, boolean[] treasurePresent) {
		m_treasurePresent = treasurePresent;
		m_treasurePositionData = treasurePositionData;
	}
	@Override
	public boolean isPresent() {
		return m_treasurePresent[m_treasurePresentIndex++];
	}

	@Override
	public Point getDrift() {
		return new Point(m_treasurePositionData[m_treasurePositionIndex++], 0);
	}

	@Override
	public void onDetect(boolean present, Point center, float radius) {
	}

}
